package q.yazg;

import java.util.Objects;

/**
 *
 * @author khalisq
 */
public class InternalMessage implements Message{
    
    private final Object obj;

    public InternalMessage(Object obj) {
        this.obj = obj;
    }

    public Object getObj() {
        return obj;
    }

    @Override
    public boolean equals(Object o) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final InternalMessage other = (InternalMessage) o;
        if (obj!=other.obj) {
            return false;
        }
        return true;
    }

    @Override
    public int hashCode() {
        int hash = 3;
        hash = 83 * hash + Objects.hashCode(this.obj);
        return hash;
    }
    
    public String toString(){
        return "InternalMessage[" + obj + "]";
    }
    
}
